using MediatR;
using TerritoryGame.Domain.ValueObjects;

namespace TerritoryGame.Application.Commands;

public record CreateRoomCommand : IRequest<CreateRoomResult>
{
    public string Name { get; init; } = string.Empty;
    public string? Password { get; init; }
    public int MaxPlayers { get; init; } = 6;
    public int GameDuration { get; init; } = 180;
    public string PlayerNickName { get; init; } = string.Empty;
}

public record CreateRoomResult
{
    public bool Success { get; init; }
    public string? ErrorMessage { get; init; }
    public Guid RoomId { get; init; }
    public Guid PlayerId { get; init; }
    public PlayerColor PlayerColor { get; init; }
    public string RoomName { get; init; } = string.Empty;
    public string RoomCode { get; init; } = string.Empty;
}
